import { userStore } from "@/store/useStore";
import jwt_decode from "jwt-decode";
export default () => {
  const jwt = localStorage.getItem("auth_token") || "";
  if (jwt) {
    let token: any = null;
    token = jwt_decode(jwt);

    !!token && userStore().setUser(token);
  }
};
